<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>《药品经营许可证》补证</title>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
    <link rel="stylesheet" href="#(basePath)/static/jquery-weui/css/weui.min.css">
    <link rel="stylesheet" href="#(basePath)/static/jquery-weui/css/jquery-weui.min.css">
    <link rel="stylesheet" href="#(basePath)/static/web/index/css/index.css">
</head>
<body>
<div class="page">
    <div class="page__hd">
        <header class="weui-header">
            <h1 class="weui-header-title">《药品经营许可证》<br/>补证</h1>
        </header>
    </div>
    <div class="page__bd page__bd_spacing">
        <form action="#(basePath)/wfw/spyxmp/ypjyxkz/save" method="post" data-role="form">
            <input type="hidden" name="type" value="1">

            #set(bzlx=data.bzlx??==null?'':data.bzlx)
            <div class="weui-cells weui-cells_checkbox">
                <div class="weui-cell weui-cell__title">
                    补证类型？
                </div>
                <label class="weui-cell weui-check__label" for="bzlx1">
                    <div class="weui-cell__hd">
                        <input type="checkbox" class="weui-check" name="bzlx" id="bzlx1" value="1" required
                               #(bzlx.contains('1')?"checked":"")>
                        <i class="weui-icon-checked"></i>
                    </div>
                    <div class="weui-cell__bd">
                        <p>药品经营许可证</p>
                    </div>
                </label>
                <label class="weui-cell weui-check__label" for="bzlx2">
                    <div class="weui-cell__hd">
                        <input type="checkbox" class="weui-check" name="bzlx" id="bzlx2" value="2" required
                               #(bzlx.contains('2')?"checked":"")>
                        <i class="weui-icon-checked"></i>
                    </div>
                    <div class="weui-cell__bd">
                        <p>药品经营质量管理规范认证证书</p>
                    </div>
                </label>
            </div>

            #set(ypjyxkzShow=bzlx.contains('1')?"block":"none")
            <div id="ypjyxkz" style="display: #(ypjyxkzShow);">
                <div class="weui-cells__title">药品经营许可证</div>
                <div class="weui-cells">
                    <div class="weui-cell weui-cell_select weui-cell_select-before">
                        <div class="weui-cell__hd">
                            <select class="weui-select" name="spjyxkzPrefix">
                                <option value="粤CB">粤CB</option>
                                <option value="粤DB">粤DB</option>
                            </select>
                        </div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" type="number" name="xkzbhPrefix" value="#(data.xkzbh??)"
                                   data-name="ypjyxkz"
                                   placeholder="请输入相关编号" required>
                            <input type="hidden" name="xkzbh" value="#(data.xkzbh??)">
                        </div>
                    </div>
                </div>
                <div class="weui-cells weui-cells_radio weui-cells_radio_native">
                    <div class="weui-cell weui-cell__title">
                        补证类型？
                    </div>
                    <label class="weui-cell weui-check__label" for="zfblx1">
                        <div class="weui-cell__bd">
                            <input type="radio" class="weui-check" name="zfblx" value="1" id="zfblx1" required
                                   #(data.zfblx??=="1"?"checked":"")>
                            <span>正本</span>
                        </div>
                    </label>
                    <label class="weui-cell weui-check__label" for="zfblx0">
                        <div class="weui-cell__bd">
                            <input type="radio" class="weui-check" name="zfblx" value="0" id="zfblx0" required
                                   #(data.zfblx??=="1"?"checked":"")>
                            <span>副本</span>
                        </div>
                    </label>
                </div>
            </div>
            #set(gspShow=bzlx.contains('2')?"block":"none")
            <div id="gsp" style="display: #(gspShow);">
                <div class="weui-cells__title">药品经营质量管理规范认证证书</div>
                <div class="weui-cells">
                    <div class="weui-cell weui-cell_select weui-cell_select-before">
                        <div class="weui-cell__hd">
                            <select class="weui-select" name="gspPrefix" style="width: 150px;">
                                <option value="C-GD-12-DG-">C-GD-12-DG-</option>
                                <option value="C-GD-13-DG-">C-GD-13-DG-</option>
                                <option value="C-GD-14-DG-">C-GD-14-DG-</option>
                                <option value="C-GD-15-DG-">C-GD-15-DG-</option>
                                <option value="C-GD-16-DG-">C-GD-16-DG-</option>
                                <option value="C-GD-17-DG-">C-GD-17-DG-</option>
                                <option value="C-GD-18-DG-">C-GD-18-DG-</option>
                            </select>
                        </div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" type="number" name="gfrzsbhPrefix" value="#(data.gfrzsbh??)" data-name="gsp"
                                   placeholder="请输入相关编号" required>
                            <input type="hidden" name="gfrzsbh" value="#(data.gfrzsbh??)">
                        </div>
                    </div>
                </div>
            </div>
            #set(qtShow=bzlx!=""?"block":"none")
            <div id="qt" style="display: #(qtShow);">
                <div class="weui-cells">
                    <div class="weui-cell weui-cell__title">
                        补正原因
                    </div>
                    <div class="weui-cell">
                        <div class="weui-cell__bd weui-cell__primary">
                            <textarea class="weui-textarea" placeholder="请输入补证原因" rows="3" name="reason" required>#(data.reason??)</textarea>
                        </div>
                    </div>
                    <div class="weui-cell weui-cell__title">
                        备注
                    </div>
                    <div class="weui-cell">
                        <div class="weui-cell__bd weui-cell__primary">
                        <textarea class="weui-textarea" rows="4" name="bz" required
                                  placeholder="企业法人的非法人分支机构申请补发《药品经营许可证》、《GSP认证证书》的，须由上级法人在“备注”栏中签署意见（法定代表人签字、盖公章）">#(data.bz??)</textarea>
                        </div>
                    </div>
                </div>

                <div data-role="upload"
                     data-content='{"label": "作废声明（<label style=color:red>或情况说明，需盖章</label>）", "params": {"tableName": "SPYXMP_YPJYXKZ", "sblsh":"#(data.APPLYID??)"}}'>
                </div>
                <div class="weui-cells">
                    <div class="weui-cell">
                        <div class="weui-cell__hd"><label class="weui-label">声明日期</label></div>
                        <div class="weui-cell__bd">
                            <input class="weui-input" type="date" name="smrq" value="#(data.smrq??)"
                                   placeholder="请选择声明日期" required>
                        </div>
                    </div>
                </div>
            </div>
            <div class="weui-btn-area">
                #if(model??=="readonly")
                <a href="#(basePath)/wfw/spyxmp/applyItem/toSbls" class="weui-btn weui-btn_primary">返回申报历史</a>
                #else
                <button class="weui-btn weui-btn_primary" type="submit">提交申请</button>
                #end
            </div>
            <br><br>
        </form>

    </div>
    <div class="page__footer">

        #include("/WEB-INF/main/footer-spyxmp.html")
    </div>
</div>
<script src="#(basePath)/static/js/weuiUpload.js"></script>
<script src="#(basePath)/static/web/spyxmp/js/xkzbh.js"></script>
<script type="text/javascript">
    $(function(){
        $('input[name=bzlx]').change(function(){
            if($(this).val() == 1){
                var ypjyxkz_checked = $(this).prop('checked');
                if(ypjyxkz_checked){
                    $('#ypjyxkz').show();
                }else{
                    $('#ypjyxkz').hide();
                }
            }else if($(this).val() == 2){
                var gsp_checked = $(this).prop('checked');
                if(gsp_checked){
                    $('#gsp').show();
                }else{
                    $('#gsp').hide();
                }
            }

            if($('#qt').is(':hidden')){

                $('#qt').show();
            }else if($('input[name=bzlx]:checked').length == 0){

                $('#qt').hide();
            }
        });
    })
</script>
</body>
</html>